package com.briup.cms.dao;


import com.briup.cms.bean.Role;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;
import org.springframework.stereotype.Service;

import java.util.List;


public interface RoleMapper {


    @Select("select * from cms_role")
    List<Role> selectAll();


    @Insert("insert into cms_role values(null,#{name})")
    void insert(Role role);
    @Update("update cms_role set name=#{name} where id=#{id}")
    void update(Role role);
    @Delete("delete from cms_role where id=#{id}")
    void deleteById(long id);

}
